User blog:Davazz/Vehicle top speeds
Hello folks, I wanted to share some knowledge about engine upgrades in Driver:PL with you. Be warned, a lot of maths is involved, so I hope you understand :P In the game directory is a file called 'VVars.txt'. It is located in the map 'Vehicles'. I'll paste some of its content here. As you can see, the stage 1 and stage 2 engine add 0.1 (=10%) to the top speed, and the stage 3 engine adds 0.05 (=5%). With this knowledge we can set up a mathematical formula to calculate a cars top speed for a vehicle with a stage 1 of 2 engine (if you know the exact top speed of the default vehicle)... vtop = vstock x 1.1n In which: vtop stands for the top speed; vstock stands for the default speed (with no engine upgrades); n stands for the amount of engine upgrades (thus engine stage 1 would give '1' as value and stage 2 '2') This formula basically adds two times 10% to the top speed. Example: If the default top speed of a car is 90 mph, the top speed with a stage 2 engine would be: 90 x 1.12 = 108.9 mph. ... and we can also create a formula for stage 3 engines. Because the stage 3 engine adds 0.05% to the top speed, the formula for the top speed with that engine would be: vtop = vstock x 1.12 x 1.05 In this case that would be 90 x 1.12 x 1.05 = 114 Mph. The stage 3 formula is different than the one described above, because the third engine upgrade doesn't add 10%, but 5% to the top speed. Ok, so we got the formulas. No let's try it with the top speed of the Rhapsody. I did some tests on La Guardia airfield in the 2006 era (in this era the speedometer displays the speed digitally, which makes it easier to obtain the exact speed). I equipped each car with nitros (when not used they don't influence top speed/acceleration) and gave each test car a boost until they almost reached their top speed. I did this because even when you diagonally cross the entire airport it is, with stage 2 and 3 engines, still not long enough to reach a constant top speed. Then I stopped boosting and only accelarated, until the car reached its top speed and these are the exact results: To prove the formula is right, let's insert some data into the formula. The Stage 1 Top speed would be: 78 x 1.11 = 85.8 Mph = 86 Mph. This is consistent with the table. The Stage 3 Topspeed would be: 78 x 1.12 x 1.05 = 99.1 Mph = 99 Mph. This is also consistent with the table. But when we insert the data of engine stage 2, we see that it will not give the correct value: 78 x 1.12 = 94.3 Mph = 94 Mph, which is not consistent with the table. You might think that there occured measurement errors during the test, but that's not possible. The values of '78' and '95' Mph can not be a mile more or less, because the car can reach both speeds without any boost, but when boosted, the speed drops to those exact values, which means they are the correct top speeds. What this means is that the default value top speed of the Rhapsody is not 78 Mph, but approximately 78 (and so are the other top speeds), which is pretty weird. Some more calculations make clear that the top speed of the stock Rhapsody must be a value between approximately 78.01 and 78.24 Mph. I calculated this by assuming that e.g. if the speed gauge displays 95 Mph, the actual speed must be between 94.5 and 95.4, since these numbers will both become 95 on the speed gauge. With this in mind, I calculated the domain above. I also tested the Cerrano on this, and the same conclusion can be drawn here: the top speed of the stock version is approximately 95 Mph. Well, that's what I wanted to say. I hope you now understand a little bit more about how engine upgrades actually work. Also, there's more data in the VVars.txt, but in this blog i focussed on the top speed. You can open this file yourself too, with Notepad. Fun thing to try is setting the 'cogh' value on -20 in engine stage one. Don't forget to backup the file somewhere in case you forgot the default values. Next step would be to get the exact values of the every top speed of every car in the game, but so far they are not known yet... Category:Blog posts